package com.example.springbootdockerdemo.service.impl;

import com.example.springbootdockerdemo.service.UserService;
import org.springframework.stereotype.Service;

import javax.annotation.PostConstruct;

/**
 * @ClassName UserServiceImpl
 * @Author Chengy
 * @Date 2021/11/22 13:46
 * @Version 1.0
 */

@Service
public class UserServiceImpl implements UserService {
    @Override
    public Object eat(String eat) {
        System.out.println("去干饭");
        return "干了八只";
    }

    @Override
    public void out() {
        System.out.println("出去浪");
    }

    @Override
    public void shit() {
        System.out.println("去拉屎");
        System.out.println("手机掉茅坑了");
    }

    @PostConstruct
    public void init(){
        out();
        System.out.println("@PostConstruct启动时加载注解");
    }


}
